package org.example.domain.model.entity.url.mapstruct;

import org.example.domain.model.entity.url.resp.QueryGroupByCountResp;
import org.example.domain.model.entity.url.resp.UrlShortenerGroupResp;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;


@Mapper
public interface UrlShortenerGroupRespMapstruct {
    UrlShortenerGroupRespMapstruct INSTANCE = Mappers.getMapper(UrlShortenerGroupRespMapstruct.class);

    UrlShortenerGroupResp queryGroupByCountRespToUrlShortenerGroupResp(QueryGroupByCountResp queryGroupByCountResp);
    /**
     * Mapstruct不能只用list会 程序编译时出现报错 No target bean properties found
     * 解决方法： 在List类型转换的前面加上一个同名实体类转换类转换 (queryGroupByCountRespToUrlShortenerGroupResp)
     */
    List<UrlShortenerGroupResp> queryGroupByCountRespListToUrlShortenerGroupRespList(List<QueryGroupByCountResp> queryGroupByCountRespList);
}
